The present disclosure relates to a semiconductor device and is applicable to a semiconductor device having a failure detection function, for example.
An in-vehicle microcontroller includes a safety mechanism to monitor operation of a CPU of the microcontroller in addition to safety mechanisms such as an ECC (Error Correction Code) circuit provided for SRAM or flash memory and a BIST (Built in Self Test) circuit to perform self-diagnosis.
The dual lockstep (hereinafter referred to as a lockstep) is a most popular system as the safety mechanism to monitor CPU operations. The system synchronizes clocks of two CPUs mounted on one semiconductor chip and concurrently allows each CPU to perform the same process. The system allows a comparison circuit to compare processing results from the CPUs with each other and performs the process only when the processing results are identical. The lockstep is disclosed in U.S. Patent Application Publication No. 2013/038945, for example.    Patent Literature 1: U.S. Patent Application Publication No. 2013/038945